Add tests for backup#588
Open
sjha4 wants to merge 3 commits into
Open
Conversation
95d6d11 to
727cdd8
Compare
sjha4
commented
Jun 23, 2026
359bea6 to
736e9d2
Compare
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
| """ | ||
| Test that foremanctl state directory is archived. | ||
|
|
||
| NOTE: This test is conditional because foremanctl-state.tar.gz is only |
Member
There was a problem hiding this comment.
This test should not be conditional, that tells me there is a design flaw that should be fixed.
Contributor
Author
There was a problem hiding this comment.
I have updated backup to handle localhost and quadlet based deployments. Have kept it as a separate commit to isolate the change there..
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
ehelms
reviewed
Jun 29, 2026
574985c to
7a0eb4c
Compare
ehelms
reviewed
Jul 2, 2026
96d9ed4 to
af5224e
Compare
Contributor
Author
|
@ehelms Greenery.. 🥗 |
sjha4
commented
Jul 7, 2026
ehelms
reviewed
Jul 8, 2026
| become: false | ||
| register: backup_temp_dir | ||
|
|
||
| - name: Archive foremanctl state on controller |
Member
There was a problem hiding this comment.
Could you do this within the obsah_state_path?
- generate archive inside obsah_state_path
- transfer to target location
Then no temporary directory or cleanup is needed?
Contributor
Author
There was a problem hiding this comment.
Updated to archive /var/lib/foremanctl/ directory on target into the backup directory on target..No cleanup/temp files../var/lib/foremanctl works on localhost, quadlet and proxy where the obsah_state_path will be mounted.. 👍🏼
b2063ea to
b627a88
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why are you introducing these changes? (Problem description, related links)
Add tests for foremanctl backup
What are the changes introduced in this pull request?
How to test this pull request
The CI should run the new tests.
Steps to reproduce:
Checklist
PS: I had some issues with the OBSAH_STATE_PATH running these locally in a repo checkout. The backup is supposed to work on a host with services deployed and with path as /var/lib/foremanctl. The repo setup is different from production-like installs where the quadlet is mapped to localhost. On dev setup, quadlet is actual VM so the test finds OBSAH_STATE_PATH as /.var/lib/foremanctl inside the VM. Hence the conditional test for foremanctl state archive which archives this path.